package com.authine.cloudpivot.ext.applicationservice.v1.sourcing.vo;

import com.authine.hermes.app.launcher.cmd.Attachment;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.util.StringUtils;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;


@Data
@NoArgsConstructor
@AllArgsConstructor
@ApiModel("询价商品VO")
public class InquiryGoodsVO {

    //需求转询价或者再次询价时，先赋上id。没有id子表无法被选中
    @ApiModelProperty(value = "商品id")
    private String id;

    @ApiModelProperty(value = "外部来源client_id")
    @JsonProperty("clientId")
    private String client_id;

    @ApiModelProperty(value = "外部来源询价商品id")
    @JsonProperty("clientInquiryGoodsId")
    private String client_inquiry_goods_id;

    @ApiModelProperty(value = "平台类目名称")
    @JsonProperty("platformCategoryName")
    private String platform_category_name;

    @ApiModelProperty(value = "收货地址")
    private String address;

    @ApiModelProperty(value = "数量")
    private BigDecimal num;

    @ApiModelProperty(value = "单位")
    private String unit;

    @ApiModelProperty(value = "询价商品名称")
    private String name;

    @ApiModelProperty(value = "品牌")
    private String brand;

    @ApiModelProperty(value = "型号")
    private String model;

    @ApiModelProperty(value = "货期")
    private String delivery;

    @ApiModelProperty(value = "询价单id")
    @JsonProperty("inquiryId")
    private String inquiry_id;

    @ApiModelProperty(value = "客户料号")
    private String sku;

    @ApiModelProperty(value = "类别")
    private String category;

    @ApiModelProperty(value = "规格")
    private String spec;

    @ApiModelProperty(value = "需求部门")
    @JsonProperty("demandDepartment")
    private String demand_department;

    @ApiModelProperty(value = "包装数量")
    @JsonProperty("packageNum")
    private BigDecimal package_num;

    @ApiModelProperty(value = "包装单位")
    @JsonProperty("packageUnit")
    private String package_unit;

    @ApiModelProperty(value = "附件信息")
    private String attachment;

    @ApiModelProperty(value = "格式化后的附件信息")
    private List<Attachment> attachments;

    @ApiModelProperty(value = "参考链接")
    private String url;

    @ApiModelProperty(value = "备注")
    private String memo;

    @ApiModelProperty(value = "描述")
    private String description;

    @ApiModelProperty(value = "报价时是否可编辑")
    private Boolean quoteEditable;

    @ApiModelProperty(value = "是否上传代理资质")
    @JsonProperty("itemType")
    private Integer item_type;

    @ApiModelProperty(value = "报价时是否可以编辑")
    @JsonProperty("quoteEditLimit")
    private Integer quote_edit_limit;

    @ApiModelProperty(value = "询价单")
    private InquiryVO inquiryVO;

    @ApiModelProperty(value = "条形码编号")
    @JsonProperty("barCode")
    private String bar_code;

    @ApiModelProperty(value = "修改人")
    private String modifiedBy;

    @ApiModelProperty(value = "单据状态")
    private String status;

    @ApiModelProperty(value = "报价次数")
    @JsonProperty("quoteCount")
    private Integer quote_count;

    @ApiModelProperty(value = "创建时间")
    @JsonProperty("time")
    private Date createdTime;

    @ApiModelProperty(value = "虚拟供应商是否参与报价")
    private Integer participation;

    @ApiModelProperty(value = "区域")
    private String area;

    @ApiModelProperty(value = "公司")
    private String company;

    @ApiModelProperty(value = "仓库")
    private String warehouse;

    @ApiModelProperty(value = "历史采购价格")
    private String historyPurchasePrice;

    @ApiModelProperty(value = "安全库存")
    private BigDecimal safetyStockNum;

    @ApiModelProperty(value = "最大库存量")
    private BigDecimal maximumStock;

}
